package com.lzy.pattern.factory.abstract_factory;

/**
 * @ClassName: Client
 * @Description: TODO
 * @Author: LiuZy
 * @Date: 2022/4/13 20:50
 * @Version: 1.0
 */
public class Client {

    public static void main(String[] args) {
        ItalyDessertFactory factory = new ItalyDessertFactory();
        Coffee coffee = factory.createCoffee();
        Dessert dessert = factory.createDessert();

        System.out.println(coffee.getName());
        dessert.show();

        AmericanDessertFactory factory2 = new AmericanDessertFactory();
        factory2.createCoffee();
        Dessert dessert2 = factory2.createDessert();
        dessert2.show();

    }

}